package cn.edu.gxu.xingjian.teacherassistant.domain;

import javax.persistence.ManyToOne;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;
import org.springframework.roo.addon.javabean.RooJavaBean;
import org.springframework.roo.addon.jpa.activerecord.RooJpaActiveRecord;
import org.springframework.roo.addon.tostring.RooToString;

@RooJavaBean
@RooToString
@RooJpaActiveRecord
public class Curriculum {

    @NotNull
    @Size(min = 2)
    private String name;

    @NotNull
    @Size(min = 1)
    private String credit;

    @NotNull
    @Size(min = 4)
    private String curriculumNumber;

    @NotNull
    @Size(min = 1)
    private String teachingHours;

    @NotNull
    @Size(min = 2)
    private String teachingMode;

    @ManyToOne
    private MajorGrade majorGrade;

    @ManyToOne
    private Classroom classroom;
}
